package com.atguigu.gmall.mapper;

import com.atguigu.gmall.bean.InteractionVideo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

@Mapper
public interface InteractionVWMapper {
    @Select("select chapter_name,\n" +
            "       play_count,\n" +
            "       play_time,\n" +
            "       user_count,\n" +
            "       play_time/user_count avg_play_time\n" +
            "from dws_interaction_video_watch_window partition par#{date}")
    List<InteractionVideo> selectVideoList(Integer date);
}
